Skip to content

Remove gwpy#5285

Open
GarethCabournDavies wants to merge 8 commits intogwastro:masterfrom
GarethCabournDavies:remove_gwpy
Open

Remove gwpy#5285
GarethCabournDavies wants to merge 8 commits intogwastro:masterfrom
GarethCabournDavies:remove_gwpy

Conversation

@GarethCabournDavies
Copy link
Contributor

Update pycbc_live_collated_dq_trigger_rates to use pycbc-native stuff rather than gwpy. This means that we can remove gwpy from companion.txt

Closes #5257

Standard information about the request

This is a change to use already-included code rather than external processes
This change affects the live search
This change follows style guidelines (See e.g. PEP8), has been proposed using the contribution guidelines
This change will: remove a companion dependency

Testing performed

I would like to run an example of this with code before/after, but trying to find an example with still-existing files is not obvious!

  • The author of this pull request confirms they will adhere to the code of conduct

@GarethCabournDavies GarethCabournDavies requested review from Copilot and maxtrevor and removed request for Copilot February 13, 2026 16:20
@titodalcanton titodalcanton added low latency dependencies Pull requests that update a dependency file labels Feb 23, 2026
Copy link
Contributor

@titodalcanton titodalcanton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a quick look with some comments. Also, please rebase on master.

Copilot AI review requested due to automatic review settings March 5, 2026 13:03
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR removes the project’s only remaining usage of gwpy by updating the live script pycbc_live_collated_dq_trigger_rates to use PyCBC-native frame reading and DQ/segment utilities, enabling removal of gwpy from companion.txt (per #5257).

Changes:

  • Drop the gwpy dependency from companion.txt.
  • Replace gwpy DQ querying and TimeSeriesDict reading with pycbc.dq.query_flag and pycbc.frame.frame.read_frame.
  • Add a helper to convert boolean time-sampled data into igwn_segments.segmentlist and use segment operations to compute flagged livetime.

Reviewed changes

Copilot reviewed 1 out of 2 changed files in this pull request and generated no comments.

File Description
companion.txt Removes gwpy from companion dependencies.
bin/live/pycbc_live_collated_dq_trigger_rates Replaces gwpy timeseries/DQFlag logic with PyCBC frame reads and igwn segment arithmetic.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Contributor

@maxtrevor maxtrevor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, except possibly for Tito's question about catching and reraising an error

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file low latency

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remove dependency on gwpy

4 participants